/**
 * Copyright 2011 Renato de Jesus Manzoni
 * 
 * SED - Software Engineering and Dependability Research Group
 * 
 *     http://www.sed.ic.unicamp.br/
 * 
 * Distributed Systems Laboratory (LSD) in the Institute of Computing (IC) at University of Campinas (UNICAMP)
 * 
 *     http://www.lsd.ic.unicamp.br/
 * 
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package br.unicamp.ic.lsd.wscaa.model;

import br.unicamp.ic.lsd.wscaa.exception.WSDynamicException;

/**
 * @author Renato de Jesus Manzoni <rjmanzoni@gmail.com>
 *
 */
public class ServiceResponse {
	
	private String responseName = null;
	private Object[] reponses = null;
	private WSDynamicException exception = null;
	
	/**
	 * @param responseName
	 * @param reponses
	 */
	public ServiceResponse(String responseName, Object[] reponses) {
		this.responseName = responseName;
		this.reponses = reponses;
		//this.exception = exception;
	}
	
	public ServiceResponse(String responseName, WSDynamicException exception) {
		this.responseName = responseName;
		this.exception = exception;
	}

	public String getResponseName() {
		return responseName;
	}

	public void setResponseName(String responseName) {
		this.responseName = responseName;
	}

	public Object[] getReponses() {
		return reponses;
	}

	public void setReponses(Object[] reponses) {
		this.reponses = reponses;
	}

	public WSDynamicException getException() {
		return exception;
	}

	public void setException(WSDynamicException exception) {
		this.exception = exception;
	}

	public boolean hasException(){
		return exception == null ? false : true;
	}
}
